using System;

class Program
{
    static void Main(string[] args)
    {
        // 获取用户输入
        Console.Write("请输入数字一: ");
        double num1 = Convert.ToDouble(Console.ReadLine());

        Console.Write("请输入数字二: ");
        double num2 = Convert.ToDouble(Console.ReadLine());

        Console.Write("请输入运算符 (+, -, *, /): ");
        char operatorChar = Convert.ToChar(Console.ReadLine());

        // 进行计算并打印结果
        double result = 0;
        switch (operatorChar)
        {
            case '+':
                result = num1 + num2;
                break;
            case '-':
                result = num1 - num2;
                break;
            case '*':
                result = num1 * num2;
                break;
            case '/':
                if (num2 != 0)
                {
                    result = num1 / num2;
                }
                else
                {
                    Console.WriteLine(".");
                    return;
                }
                break;
            default:
                Console.WriteLine("除数不能是0.");
                return;
        }

        // 打印结果
        Console.WriteLine($"结果是: {result}");
    }
}
